package com.itheima.service.impl.rabbitmq.topic.listener;

import org.springframework.amqp.rabbit.annotation.RabbitListener;

/**
 * ClassName: MessageListener
 * Description:
 * Date: 2023/03/19 AM 11:00:12
 * <p>
 * project: springboot
 * package: com.itheima.service.impl.rabbitmq.direct
 * email: 1085844536@qq.com
 * version:
 *
 * @author WangGuojian
 */
// @Component
public class MessageListener {

    @RabbitListener(queues = "topic_queue")
    public void receive(String id) {
        System.out.println("已完成短信发送业务(rabbit topic 1), id: " + id);
    }

    @RabbitListener(queues = "topic_queue2")
    public void receive2(String id) {
        System.out.println("已完成短信发送业务(rabbit topic 2), id: " + id);
    }
}
